with v8.Class_Object, v8.Class_Value;
package v8.Class_Boolean_Object is
   type Boolean_Object (<>) is new v8.Class_Object.Object with private;
   type Pointer is access all Boolean_Object;
   -- A Boolean object (ECMA-262, 4.3.15).

   function Create (value : bool) return Pointer;
   -- return Local<Boolean_Object>

   function Boolean_Value (this : Boolean_Object) return bool;
   -- Returns the Boolean held by the object.

   function Cast is new Ada.Unchecked_Conversion (v8.Class_Value.Pointer, Pointer);
   -- convert Value to BooleanObject

private
   type Boolean_Object is new v8.Class_Object.Object with null record;

   pragma Import (CPP, Create, "_ZN2v813BooleanObject3NewEb");
   pragma Import (CPP, Boolean_Value, "_ZNK2v813BooleanObject12BooleanValueEv");
end v8.Class_Boolean_Object;
